1 00:00:00,630 --> 00:00:10,530 Hello and welcome to this lecture in this lecture will be creating too -- mention every now will hald 2 00:00:10,920 --> 00:00:14,290 information about the bricks. 3 00:00:14,330 --> 00:00:24,960 The array will contain brick column information as well as the brick rolls which will also contain an 4 00:00:25,110 --> 00:00:38,850 object containing the x and y position that will be used to paint or draw each brick on the screen to 5 00:00:38,850 --> 00:00:40,060 save some time. 6 00:00:40,070 --> 00:00:50,610 I have already created the piece of court for the two dimensional array ballads from line 22 to line 7 00:00:50,640 --> 00:00:52,770 twenty eight. 8 00:00:52,770 --> 00:00:58,130 The piece of code here what will happen is it contains a loop. 9 00:00:58,260 --> 00:01:07,170 For now it will look through the rules columns and then create new bridge. 10 00:01:07,350 --> 00:01:09,110 So let me explain. 11 00:01:09,180 --> 00:01:11,720 Could to you line 22. 12 00:01:11,730 --> 00:01:25,590 We created a variable or bricks and gave it a value of an empty horie Online 23 added a for loop. 13 00:01:26,210 --> 00:01:27,770 An inside look. 14 00:01:27,890 --> 00:01:28,310 Tool. 15 00:01:28,350 --> 00:01:35,660 Check for the column to check the value of the column is zero. 16 00:01:36,330 --> 00:01:47,500 And if the column is less than the brick column count which is this count 7. 17 00:01:47,890 --> 00:01:54,690 If it is less than that or what different form look will do just loop through this and check if there 18 00:01:54,690 --> 00:02:03,000 are they check that the cantine 0 there is no column there and any Also checks the brick column count. 19 00:02:03,370 --> 00:02:05,540 But is this here. 20 00:02:05,560 --> 00:02:08,640 If it is less than that. 21 00:02:08,880 --> 00:02:14,130 So if it is less than that it will now add column. 22 00:02:14,170 --> 00:02:19,350 If time ignores true the loop so does bloss plasmids add 1. 23 00:02:19,440 --> 00:02:21,180 So you checked the loop chips. 24 00:02:21,180 --> 00:02:29,300 This condition shows that the column is zero checks that the column is the less than the blue column 25 00:02:29,310 --> 00:02:30,210 count. 26 00:02:30,210 --> 00:02:32,440 He then adds a column. 27 00:02:32,460 --> 00:02:34,310 So there are three things it looks for. 28 00:02:34,590 --> 00:02:36,840 And this is where it will add that column. 29 00:02:36,870 --> 00:02:42,190 Inside this empty hurry here so are the bricks. 30 00:02:42,260 --> 00:02:47,740 But seeing this is the area here inside this area is the column count. 31 00:02:47,940 --> 00:02:54,350 Of course to whatever increment you add online 25 is the same thing. 32 00:02:54,360 --> 00:02:57,450 But this would be doing it for the rules. 33 00:02:57,480 --> 00:03:08,040 It checks to see if the rules are 0 and also even the rule is less than the break rule count which is 34 00:03:08,040 --> 00:03:12,020 this one here which is for is less than 4. 35 00:03:12,200 --> 00:03:20,280 It will then add 1 each time it goes to a loop until he gets the total amount defined. 36 00:03:22,480 --> 00:03:28,930 On line 26 again the bricks variable. 37 00:03:28,930 --> 00:03:31,830 You've got the two areas here. 38 00:03:31,840 --> 00:03:33,230 The one for the column. 39 00:03:33,400 --> 00:03:34,780 How one fully rule. 40 00:03:35,010 --> 00:03:40,230 And also may be equal to an object. 41 00:03:40,420 --> 00:03:47,830 So this symbol Here's an object we defined two objects for the x y axis. 42 00:03:47,860 --> 00:03:56,560 These are objects and the borgo values of zy each time the loop happens. 43 00:03:56,740 --> 00:04:08,350 A tool set the X and the y position of each brick and paint or draw a brick on the compass as thong 44 00:04:08,350 --> 00:04:12,840 as the count is relevant. 45 00:04:13,000 --> 00:04:17,260 Right now we've created the two dimensional array. 46 00:04:17,470 --> 00:04:21,650 In the next letter your will be creating a function. 47 00:04:21,790 --> 00:04:26,000 There we will used to draw the outroar bricks. 48 00:04:26,200 --> 00:04:28,170 Thank you so much for watching. 49 00:04:28,220 --> 00:04:29,540 Bye for an hour.